#include <iostream>
#include <string.h>
using namespace std;

class Cat{
    public:
    Cat(const char* _name){
       name = new char[20];
        strcpy(name,_name);
    }
    //
    Cat(const Cat &newName){
        this->name =new char[20];
         strcpy(this->name,newName.name);
         
     }
    void show(){
        cout<<name<<endl;
    }
    ~Cat(){
        delete []name;
    }
    private:
    char *name;
};


int main(int argc, char const *argv[])
{
    Cat c1("name");
    Cat c2 = c1;
    c1.show();
    c2.show();
   
    
   
    return 0;
}
